<style>
	.region_city .city-picker-span {
		width: 80% !important;
		position: relative;
	}
</style>

<form id="add-form" class="form-horizontal form-ajax" role="form" data-toggle="validator" method="POST">
	<!-- 用户昵称 -->
	<div class="form-group">
		<label for="nickname" class="control-label col-xs-12 col-sm-2">{:__('Bnickname')}:</label>
		<div class="col-xs-12 col-sm-8">
			<input
				type="text"
				class="form-control"
				id="nickname"
				name="row[nickname]"
				data-rule="required;nickname"
				placeholder="{:__('Bnickname')}"
                value="{$row.nickname}" />
		</div>
	</div>
	<!-- 邮箱 -->
	<div class="form-group">
		<label for="email" class="control-label col-xs-12 col-sm-2">{:__('Email')}:</label>
		<div class="col-xs-12 col-sm-8">
			<input
				type="text"
				class="form-control"
				id="email"
				name="row[email]"
				data-rule="required;email"
				placeholder="{:__('Email')}"
                value="{$row.email}" />
		</div>
	</div>
	<!-- 手机 -->
	<div class="form-group">
		<label for="mobile" title="手机号码" class="control-label col-xs-12 col-sm-2">{:__('mobile')}:</label>
		<div class="col-xs-12 col-sm-8">
			<input
				type="text"
				title="手机号码"
				class="form-control"
				id="mobile"
				name="row[mobile]"
				data-rule="required;mobile"
				placeholder="{:__('mobile')}"
                value="{$row.mobile}" />
		</div>
	</div>
	<!-- 密码 -->
	<div class="form-group">
		<label for="mobile" title="密码" class="control-label col-xs-12 col-sm-2">{:__('password')}:</label>
		<div class="col-xs-12 col-sm-8">
			<input
				type="password"
				title="密码"
				class="form-control"
				id="mobile"
				name="row[password]"
				placeholder="{:__('password')}，不填则不修改"/>
		</div>
	</div>
	<!-- 性别 -->
	<div class="form-group">
		<label class="control-label col-xs-12 col-sm-2">{:__('Gender')}:</label>
		<div class="col-xs-12 col-sm-8">
			<select id="c-gender" data-rule="required" class="form-control selectpicker" name="row[gender]">
				{foreach $SexList as $k => $v}
                    <option value="{$k}" selected="{$row['gender'] === $k ? true : false}">{$v}</option>
				{/foreach}
			</select>
		</div>
	</div>
	<!-- 认证状态 -->
	<div class="form-group">
		<label class="control-label col-xs-12 col-sm-2">{:__('BAuthStatus')}:</label>
		<div class="col-xs-12 col-sm-8">
			<select id="c-status" class="form-control selectpicker" name="row[auth]">
                {foreach $AuthList as $k => $v}
                    <option value="{$k}" selected="{$row['auth'] === $k ? true : false}">{$v}</option>
				{/foreach}
			</select>
		</div>
	</div>
	<!-- 余额 -->
	<div class="form-group">
		<label for="money" class="control-label col-xs-12 col-sm-2">{:__('Bmoney')}:</label>
		<div class="col-xs-12 col-sm-8">
			<input
				type="number"
				min="0"
				class="form-control"
				id="c-money"
				name="row[money]"
				data-rule="required"
				placeholder="{:__('money')}"
                value="{$row.money}" />
		</div>
	</div>
	<!-- 来源 -->
	<div class="form-group">
		<label class="control-label col-xs-12 col-sm-2">{:__('Bsource')}:</label>
		<div class="col-xs-12 col-sm-8">
            <select id="c-deal" data-rule="required" class="form-control selectpicker" name="row[sourceid]">
                {foreach $SourceList as $k => $v}
                    <option value="{$k}" selected="{$row['sourceid'] === $k ? true : false}">{$v}</option>
				{/foreach}
			</select>
		</div>
	</div>
	<!-- 成交状态 -->
	<div class="form-group">
		<label class="control-label col-xs-12 col-sm-2">{:__('BdealText')}:</label>
		<div class="col-xs-12 col-sm-8">
			<select id="c-deal" data-rule="required" class="form-control selectpicker" name="row[deal]">
                {foreach $DealList as $k => $v}
                    <option value="{$k}" selected="{$row['deal'] === $k ? true : false}">{$v}</option>
				{/foreach}
			</select>
		</div>
	</div>
	<!-- 地区 -->
	<div class="form-group">
		<label class="control-label col-xs-12 col-sm-2">地区选择:</label>
		<div class="col-xs-12 col-sm-10 region_city">
			<input id="region" readonly type="text" data-toggle="city-picker" value="{$row.regionCode}" />
			<!-- 用于提交数据把选中的地区传给后端处理 -->
			<input type="hidden" name="row[code]" id="region-code" />
		</div>
	</div>

	<!-- 按钮 -->
	<div class="form-group hidden layer-footer">
		<label class="control-label col-xs-12 col-sm-2"></label>
		<div class="col-xs-12 col-sm-8">
			<button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
			<button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
		</div>
	</div>
</form>
